#include <stdio.h>
#define N 1000
int arr2[N+1]={0};
int main_7()
{
    int n, v;
    scanf("%d",&n);
    int output[n]={0};
    for (int i=0;i<n ;i++ )
    {
        scanf("%d",&v);
        output[i]=++arr2[v];
    }
    for (int i=0;i<n ;i++ )
    {
        printf("%d ",output[i]);
    }
    return 0;
}
